#!/bin/bash
picidx=0
for FILE in  ./*.jpg; do
    mv $FILE ./wp_$picidx.jpg
    picidx=`expr $picidx + 1`
    echo $picidx
done

for FILE in  ./*.jpeg; do
    mv $FILE ./wp_$picidx.jpeg
    picidx=`expr $picidx + 1`
    echo $picidx
done

for FILE in  ./*.png; do
    mv $FILE ./wp_$picidx.png
    picidx=`expr $picidx + 1`
    echo $picidx
done
